#ifndef __GRAPH_H__
#define __GRAPH_H__

struct gnode {
    int data;
    int weight;
    struct gnode *next;
};


struct graph {
    unsigned int size;
    struct gnode *mat;
};

typedef struct  graph graph_t;

//basic operations
void initGraph(graph_t *gptr, int size);
void freeGraph(graph_t *gptr);
void addEdge(graph_t *gptr, int i, int j, int weight);
void displayMatrix(graph_t *gptr);

#endif